package com.yy.app.config.filter;

import jakarta.servlet.FilterChain;
import jakarta.servlet.ServletException;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
import org.springframework.web.filter.OncePerRequestFilter;

import java.io.IOException;

/**
 * @Description 状态参数验证过滤器
 * @Date 2025/10/10 下午6:06
 * @Author yanglin
 **/
@Component
public class StateValidationFilter extends OncePerRequestFilter {

    private static final Logger logger = LoggerFactory.getLogger(StateValidationFilter.class);

    @Override
    protected void doFilterInternal(HttpServletRequest request, HttpServletResponse response,
                                    FilterChain filterChain) throws ServletException, IOException {

        logger.debug("[SSO-AUTH-APP2] request url : {}", request.getRequestURI());

        filterChain.doFilter(request, response);
    }
}
